<template>
	<div class="bg-white">
		<div class="p-3 shadow rounded w-100">
			<Form :label-width="100">
				<Row class="w-100">
					<Col :xxl="12" :xl="8" :lg="12" :md="12" :sm="24" :xs="24">
						<FormItem class="" label="会员类型编号">
							<Input v-model="viptype.viptypeid" disabled></Input>
						</FormItem>
					</Col>
					<Col :xxl="12" :xl="8" :lg="12" :md="12" :sm="24" :xs="24">
						<FormItem class="" label="会员类型名称">
							<Input v-model="viptype.name" ></Input>
						</FormItem>
					</Col>
					<Col :xxl="12" :xl="8" :lg="12" :md="12" :sm="24" :xs="24">
						<FormItem class="" label="会员分钟">
							<Input v-model="viptype.minuts" ></Input>
						</FormItem>
					</Col>
					<Col :xxl="12" :xl="8" :lg="12" :md="12" :sm="24" :xs="24">
						<FormItem class="" label="价格">
							<Input v-model="viptype.price" ></Input>
						</FormItem>
					</Col>
					<Col :xxl="12" :xl="8" :lg="12" :md="12" :sm="24" :xs="24">
						<FormItem class="w-50" label="状态">
							<Select v-model="viptype.statu">
								<Option value="1">上架</Option>
								<Option value="0">下架</Option>
							</Select>
						</FormItem>
					</Col>
				</Row>
				<FormItem class="text-right">
					<Button @click="submit" type="primary">保存</Button>
				</FormItem>
			</Form>
		</div>
	
	</div>
</template>

<script>
	export default {
		data() {
			return {
				viptype: {
					viptypeid: "",
					name: "",
					minuts: "",
					price: "",
					statu: "",
					
					headimg: "",
					from: "",
				
				},
			}
		},
		props: {
			params: {
				type: Object,
				default: undefined,
			}
		},
		methods: {
			loadData: function() {
				return this.http.get({
					url: "/hyt/info",
					param: {
						viptypeid: this.viptype.viptypeid
					}
				}).then(res => {
					this.viptype = res;
				});
			},
		},
		created: function() {
			this.viptype.viptypeid = this.$route.query.id;
			this.loadData();
		}
	}
</script>

<style>
</style>
